package me.zk.practice1.list;

import java.time.LocalDate;
import java.util.HashMap;
import java.util.concurrent.Callable;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.Future;
import java.util.concurrent.FutureTask;
import java.util.concurrent.TimeUnit;

/**
 * @Author: zhang kai
 * @Date: 2022/01/05
 * @Description:
 */
public class Solution4 implements Callable<String> {

    public static void main(String[] args) throws ExecutionException, InterruptedException {
        FutureTask<String> future = new FutureTask<>(new Solution4());
        new Thread(future).start();
        System.out.println(future.get());
        ThreadLocal t = new ThreadLocal();
        t.set("123213");
        System.gc();
        TimeUnit.SECONDS.sleep(5);
        System.out.println(t.get());
        ConcurrentHashMap map = new ConcurrentHashMap();
        HashMap map1 = new HashMap();
    }
    @Override
    public String call() throws Exception {
        return "null";
    }
}
